<?php

class Example_Element_Site_Body
    extends OOWP_Element_Body
{

    public function __construct(array $args = array( ))
    {
        global $wp_query;

        $input = $this->merge_arguments(array(
            'contents' => array(
                'header' => new Example_Element_Site_Header( ),
                'main' => new Example_Element_Site_Main( ),
                'footer' => new Example_Element_Site_Footer( ),
            ),
        ), $args);

        parent::__construct($input);
    }

    protected function filter_element_contents($pieces)
    {
        $start = '<div id="page" class="hfeed">';
        $end = '</div>';

        array_unshift($pieces, $start);
        array_push($pieces, $end);

        return $pieces;
    }
}
